how is it that the Great Pyramid was crafted with such precision, beautifully finished and decorated inside and out, and yet the Egyptians built the King's Sarcophagus looking unfit for a king and with visible tool marks ?
We should probably begin with the obligatory comment, which applies to almost anything dating back this far into the history of ancient Egypt, that there is no definitive answer to your question. We have no significant texts to help us understand what happened during the construction of the Great Pyramid – most crucially, there are no surviving wall decorations depicting Khufu's funeral – only the evidence of what survives. In addition, the pyramid itself is such a well-known monument, and has been so heavily studied, that there are inevitably competing explanations for almost every aspect of its history. Finally, we must also bear in mind that the pyramid has been open to visitors for at least 1,200 years, and quite possibly more; we have no real way of knowing how much accumulated damage the tens of thousands of people who have been inside it have done over the years, or how much evidence, in the form of physical monuments and, perhaps, even images, may have been damaged, destroyed, or carried off as a result.
With that said, let's start with a brief review of the interior of the Great Pyramid, which comprises three main chambers - the "Subterranean Chamber," excavated deep into the bedrock of the plateau, and what are today known as the "Queen's Chamber" and the "King's Chamber" in the main body of the pyramid itself. It's generally accepted that the King's Chamber was exactly that – a repository for the body of Khufu, the Fourth Dynasty pharaoh who had the pyramid constructed for him in about 2500 B.C., but the original purpose of the other two chambers is much more disputed.
Examination of the interior of the pyramid does demonstrate that it was far from entirely "beautifully finished and decorated inside and out," as you suggest. Some parts were completed to a very high standard, but let's remember that, as originally planned, the interior of the monument was designed to be seen by only a tiny handful of people, other than its builders – the priests of the burial party. After the ceremonies required for Khufu's internment were completed, it was sealed and the intention was that it would remain sealed and inviolate for ever. That was not the case, of course; it was penetrated by tomb robbers, probably relatively early in its history, and then again, supposedly, by the Arabs of the ninth century A.D. (on whose mysterious activities I wrote in detail here.) Elements of the interior that were not designed to be seen by the burial party were not in fact finished to a high standard, as we can see from the evidence of the rough condition of the relieving chambers above the King's Chamber and the crudely-cut "well shaft", which is often interpreted as an escape passage for the masons charged with setting up the pyramid's internal system of granite plugs and other defences.
So, while it's reasonable to suppose that quality control was a very important aspect of pyramid construction, we need to remember that a good deal of what we read (especially online) of the "perfection" of the pyramid's design and its dimensions is a product of the theorising of the "pyramidiots" of the 19th century (who used its measurements to plot a timeline of history and predict the future) and the "ancient astronaut" writers of the 20th, who though the pyramid could only have been built with the help of extraterrestrial architects.
Exact dimensions and impossible-to-attain precision are particularly important for the theories of both these groups. But higher tolerances for error seem to have existed in Fourth Dynasty Egypt, which is perhaps not surprising when we consider how hard and how time-consuming it was to work stone in that period.
All this is not to say that there aren't still many mysteries surrounding the pyramid's construction. Most mysteriously, the subterranean chamber was also left in a very rough and, apparently, partially finished condition, with "floors" that are little more than a series of channels and crevices, a narrow pit perplexingly sunk to a depth of about 60 feet (18 metres), and a tunnel that heads off into the bedrock only to terminate abruptly after about 50 feet (16 metres). There is no consensus as to why this chamber was left in such an incomplete condition. One theory – which gains some credence from the fact that subterranean burial chambers are the norm for other pyramids (indeed Khufu's is the only one to contain a network of chambers above ground) is that the plans for construction of the Great Pyramid changed while it was being built; the pharaoh's burial place was shifted from the subterranean chamber to the King's Chamber, and the subterranean chamber was left unfinished as a result. But Mark Lehner of the University of Chicago – who despite his odd and frankly dubious antecedents is recognised as a leading authority on the Giza complex today – points out that the passage leading down to it is too narrow to have allowed a sarcophagus to be manoeuvred down it; since there is no trace of one in the subterranean chamber now, it may be that it was never intended as a burial chamber. It has, instead, been suggested that this chamber was deliberately constructed to represent the Egyptian underworld, and that it was the last, and not the first, of the interior elements to be begun. In this interpretation, the rough state of the chamber is a product of the death of Khufu, which necessitated an immediate cessation of work so that he could be buried and the pyramid sealed.
Whatever the truth, the takeaway from this discussion is that it was not considered necessary to finish every part of the pyramid to the highest possible standard; in addition, the Great Pyramid is notably entirely devoid of any "decorations" other than the more impressive elements of its architecture. Many Egyptologists would also dispute that the King's Chamber itself is roughly finished. For the most part, it is constructed to immensely fine tolerances, although it is certainly noticeable that the floor is not exactly level, being about 1.5 inches (nearly 4cm) off true at one end. However, the stones used to construct it were clearly carefully selected (they are the largest and heaviest in the entire pyramid complex, weighing as much as 50 tons apiece) and they are made of a special red granite that was apparently shipped about 500 miles (900km) down the Nile from a quarry at Aswan. The only other use of red granite in the Giza complex that I know of is in the pyramid of Menkaure, in which the same stone is used to line its North Corridor.
As for the sarcophagus itself: it is typical of the burials we know of from its period. It has also been measured many times, and a lot of incorrect figures circulated online, which may explain why it is often thought to be too small to contain a body. In reality, it is 7 foot six inches (227 cm) long, with internal dimensions of six and a half feet by 2 feet 2 inches (198x 68cm), easily large enough to hold the pharaoh's coffin(s), and it is made of the same red granite as the rest of the King's Chamber. It is free-standing and today is found at one end of the chamber, but it's usually speculated it would have been originally placed in the centre, perhaps positioned on a north-south axis. The well-known Victorian-era archaeologist Flinders Petrie seems to have been the first to note that the sarcophagus is an inch or so wider than the entrance to the King's Chamber, which implies that it must have been placed in situ during construction, not brought in after the pyramid was completed.
Petrie also noted that the sarcophagus was "not finely wrought" and compared it unfavourably to that of Khufu's son Khafre, whose sarcophagus can still be found within the Second Pyramid on the Giza plateau. He considered that the saw-marks that you draw attention to were made by the original builders. I suppose that it is not completely impossible that they were made by later visitors to the pyramid, but, if they were, it was for reasons that utterly defy us, whereas Petrie believed that he could reconstruct the thought-processes of Khafre's masons:
On the outer sides the lines of sawing may be plainly seen: horizontal on the N., a small patch horizontal on the E., vertical on the S., and nearly horizontal on the W.; showing that the masons did not hesitate at cutting a slice of granite 90 inches [2.3 metres] long... On the N. end is a place, near the W. side, where the saw was run too deep into the granite, and was backed out again by the masons; but this fresh start they made was still too deep, and two inches lower they backed out a second time, having altogether cut more than 1/10 inch [about 2.5mm] deeper than they intended. On the E. inside is a portion of a tube drill hole remaining, where they tilted the drill over into the side by not working it vertically. They tried hard to polish away all that part, and took off about 1/10-inch thickness all around; but they still had to leave the side of the hole 1/10 inch deep, 3 long and 1.3 wide; the bottom of it is 8 or 9 [inches] below the original top of the coffer. They made a similar error on the N. inside, but of a much less extent.
The saw required to make the cuts you mention was, according to Petrie at least, probably about 9 feet long and made of "jewelled bronze".
As a follow-up question, I have always been puzzled by how small the sarcophagus is. It's cut from the same granite as the rest of the chamber, so it's clearly original but it appears way too small to fit an adult body with a burial mask and other accesories. Is there any scholarly explanation for the Sarcophagus' awkward size?